Most color digital images consist of three color components: red, green and blue (RGB). All digital images are divided spatially into discrete picture elements (pixels). For each pixel in a RGB digital image, three digital values, one each for the red, green and blue components, are assigned in proportion to the brightness level of each color component in said pixel. In combination, the relative magnitudes of the digital values for each of the three color components for a pixel describe the overall brightness value and the color hue value of the pixel. If, for a pixel in a digital image, the magnitudes of the red, green and blue digital values for said pixel are equivalent, the pixel is said to be neutral in color hue. If all of the pixels in a digital image are neutral in color hue, the digital image is classified as being grayscale or “black-and-white.” If all of the pixels in a digital image have varying brightness levels but have identical or similar color hue values, the digital image is classified as being monochromatic. Traditional sepia tone (reddish-brown to yellowish-brown color hue) images are a subset of the class of monochromatic images.
Digital images are commonly obtained directly from still digital cameras and from hardcopy print or film scanners. Still digital cameras and print or film scanners typically capture digital images in RGB color. Some cameras and scanners offer on-board digital image processing capabilities to convert the original RGB color images to black-and-white and sepia tone images. Likewise, some computer software programs can convert RGB digital images to black-and-white or traditional sepia tone images, as well as to images containing exclusively other primary monochromatic color hues. Furthermore, more advanced computer software programs provide the ability to convert only some regions of a RGB digital image to black-and-white or monochromatic tones, leaving selected key regions of the image in RGB color. Digital images of this type are known as “spot color”, “accent color” or “key color” images. When black-and-white digital images, monochrome digital images, or black-and-white or monochromatic digital images with spot color are generated from original RGB digital images, the resulting digital images are often stored in three-channel (RGB) digital image files, indistinguishable in format or structure from other RGB digital image files.
When a RGB digital image file is accessed and utilized by a digital imaging system, it is often desirable to identify the class to which the digital image belongs, (e.g., RGB color, black-and-white, monochromatic, black-and-white with spot color or monochromatic with spot color), so that subsequent digital image processing operations, digital image storage formats or locations and/or image printing operations can be optimized dependent upon the actual image class. Unfortunately, many digital image files that have been originally generated as black-and-white or monochromatic or as original RGB digital images that have been subsequently converted to black-and-white or monochromatic by computer software are stored in RGB image file formats, and they carry no distinction with respect to their actual image class. It is necessary for an observer to manually classify the image into one of said classes by viewing an initial hardcopy print of the image or a softcopy reproduction of the image displayed on a color computer monitor or other such color digital image viewing device.
When large groups of digital images are imported into image archiving and management systems, image enhancement systems, and/or image printing systems, it is desirable for the system to identify the class to which an individual image belongs without the manual intervention of an observer. Image classification results can be used to selectively apply image enhancements differently to different classes of images. For example, it is usually not desirable to adjust the color balance of any images that belong to the class of monochromatic images. As another example, it might be desirable to direct digital images of different classes to different digital storage locations in an image management system. Likewise, it might be desirable to print all digital images classified as black-and-white on a different hardcopy printer than the hardcopy printer chosen to print RGB color digital images, or to choose a different set of printer inks or toners to print digital images classified as black-and-white or monochromatic as opposed to images classified as RGB color digital images on a single printer.
Using mathematical methods to determine if individual pixels of a RGB digital image are neutral or nearly-neutral have been described in prior art. The value for each color component of a pixel can be compared directly to the other two components, or the RGB pixel values can be converted to an orthogonal color space, consisting of a single luminance (brightness or lightness) value and two chrominance (color difference) values, followed by a comparison of the two chrominance values of the pixel. Example orthogonal color spaces include the CIELAB and CIELUV color spaces. Pixels having chrominance values equal to zero (i.e., at the origin of the chrominance plane) have no color content, and are determined to be neutral. Such would be the expected outcome if the pixels in a RGB color digital image are converted to black-and-white using computer software.
Pixels with both chrominance values close to zero are determined to be nearly-neutral when the absolute values of the chrominance values are within a programmable threshold from the origin of the chrominance plane. Detecting nearly-neutral pixels is advantageous when the original RGB digital image had been generated, for example, by scanning a black-and-white hardcopy image with a RGB color scanner, the output RGB digital signals of which include quantized electronic noise from the analog RGB signals produced by the scanner.
It is a simple extension of these operations to calculate the fraction of the total number of pixels in a RGB digital image that are neutral and/or nearly-neutral, and from that determination, to classify the RGB image as a black-and-white image, or a partially black-and-white image, indicative of a black-and-white image with spot color content.
A computer-based method to identify monochromatic digital images that are not black-and-white requires additional mathematical operations, analysis and classification methods. A monochrome digital image typically does not contain neutral RGB pixels, especially in the range of lightness levels excluding the minimum and maximum ranges. Furthermore, each non-neutral RGB pixel in a monochrome digital image will have a color hue characteristic similar to all other RGB pixels in the same monochrome digital image. Images traditionally classified as “sepia-toned” are a subset of the total class of monochrome images. Sepia-toned images are known for their characteristic hue. Monochromatic hues typically associated with sepia images range from yellowish brown to reddish brown. Sepia-toned RGB digital images are readily generated by scanning original sepia-toned photographs using an RGB scanner, or by using computer software to convert an original RGB color digital image or black-and-white digital image to a sepia-toned RGB image.
The dominant hue characteristic of monochrome images has been discussed in prior art, and U.S. Pat. No. 6,580,824 discloses a method to detect if a RGB digital image had been created by scanning a sepia-toned print image. The invention described by U.S. Pat. No. 6,580,824 pertains to determining the probability that a digital image is sepia-toned. No provision is understood to be included to determine if an image is monochromatic with a hue other than traditional sepia. The mechanism by which U.S. Pat. No. 6,580,824 detects a sepia image is understood to be wholly based on independently determining the hue of each of the individual pixels in the image, and comparing that hue value to a predetermined range of hues and saturations associated with sepia tones. The utility of this method is understood to be limited to the detection of traditional sepia-toned RGB digital images, and it is understood to require the predetermination of a range of hue and saturation values to define the limits of sepia color space. Further, it is understood to require the use of an algorithm “training” operation, using a pre-selected population of sepia-toned RGB digital images, to define the relevant range of the hue and saturation values that represent real sepia-toned RGB image pixel values, so that the determined range can be used in the subsequent classification of pixels from input RGB digital images of unknown classification. A disadvantage of this method is apparent if a sepia-toned RGB digital image with dominant sepia tones outside of the hue and saturation limits defined by the training set of sepia-toned images is analyzed by the described method. In this case, the sepia-toned RGB digital image would not be classified as sepia-toned. The method described by U.S. Pat. No. 6,580,824 can be extended to detect and separately classify monochromatic RGB digital images having monochromatic hues different from those associated with traditional sepia-toned monochromatic images, provided that a pre-selected population of the appropriate monochromatic RGB digital images has been used to train the algorithm.
With the rapid growth in the number of sources for RGB digital images and the number of computer-based RGB digital image enhancement methods, a need has emerged for a computer-based method to identify those RGB digital images that are black-and-white or generally monochromatic, so that subsequent image processing methods are chosen appropriately, depending upon the identified classification of the RGB digital images. Furthermore, it is generally recognized that black-and-white images with spot color and monochromatic images with spot color are members of subclasses of the black-and-white and monochromatic image classes, respectively, and as such must be distinguished from otherwise full-color RGB digital images. Therefore, a need exists for classifying RGB digital images into exclusive classes of black-and-white, monochromatic, black-and-white with spot color, monochromatic with spot color and full-color RGB image classes with reduced or no user interaction.